package yf.mall.entity;


import lombok.Setter;
import lombok.Getter;
import java.io.Serializable;
import java.util.Date;


/**
 * 讲堂实体
 * 表名 course
 *
 * @author hxf
 * @email 505860922@qq.com
 * @date Mon Oct 21 10:16:15 CST 2019
 */
@Setter
@Getter
public class CourseEntity implements Serializable {
    private static final long serialVersionUID = 1L;

    //
    private Long id;
        //课程ID
    private Long goodsId;
        //ENUM-状态:"WAIT-未开课","OPEN-已开课","CLOSED-已经结束"
    private Integer status;
        //省
    private String province;
        //市
    private String city;
        //县
    private String county;
        //详细地址
    private String detail;
        //开课时间
    private Date time;
        //起止时间
    Date[] times;
        //报名结束时间
    private Date endSign;
        //起止时间
    Date[] endSigns;
        //课程名
    private String name;
        //课程图
    private String img;
        //开课人数
    private Integer number;
        //备注
    private String remark;
        //管理员编号
    private String adminCode;


    
    public CourseEntity(){

    }

    public CourseEntity(Long goodsId, Integer status, String province, String city, String county, String detail, Date time, Date endSign, String name, String img, Integer number, String remark, String adminCode) {
        this.goodsId = goodsId;
        this.status = status;
        this.province = province;
        this.city = city;
        this.county = county;
        this.detail = detail;
        this.time = time;
        this.endSign = endSign;
        this.name = name;
        this.img = img;
        this.number = number;
        this.remark = remark;
        this.adminCode = adminCode;
    }

    public String getAddress(){
        return this.city+this.province+this.county;
    }

}
